package org.raymond.iworks.apis;

import org.raymond.iworks.apis.common.Result;
import org.raymond.iworks.apis.fallbackFactory.ITRolePermissionServiceFallbackFactory;
import org.raymond.iworks.apis.vo.role.UserRoleVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

//@Resource(name="role-permission")
@FeignClient(name="admin", contextId="role-permission",
        fallbackFactory = ITRolePermissionServiceFallbackFactory.class
)
public interface ITRolePermissionServiceApi {
    //@Resource(name="role-permission:edit")
    @PostMapping("/role-permission/create")
    Result<UserRoleVO> create(@RequestBody UserRoleVO vo);

    //@Resource(name="role-permission:edit")
    @PostMapping("/role-permission/delete")
    Result<Boolean> delete(@RequestBody UserRoleVO vo);
}
